x86/soft-reset: Drop gfn reference after calling get_gfn_query()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 7 Nov 2018 12:25:19 +0000 (12:25 +0000)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Thu, 22 Nov 2018 17:58:46 +0000 (17:58 +0000)
commite7969e917cef276318f722a607985a2e896aeb94
tree74c88e9d2ce4f4a6bf3304ec31ad80f7390834bd
parente03885248cb965ed23b51df0c044a762c7d339ad
x86/soft-reset: Drop gfn reference after calling get_gfn_query()

get_gfn_query() internally takes the p2m lock, and this error path leaves it
locked.

This wasn't included in XSA-277 because the error path can only be triggered
by a carefully timed phymap operation concurrent with the domain being paused
and the toolstack issuing DOMCTL_soft_reset.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/domain.c